Skip to content

fix: use standard TYPO3 XLF label keys for backend modules#92

Merged
CybotTM merged 2 commits intomainfrom
fix/xlf-module-label-keys
Mar 1, 2026
Merged

fix: use standard TYPO3 XLF label keys for backend modules#92
CybotTM merged 2 commits intomainfrom
fix/xlf-module-label-keys

Conversation

@CybotTM
Copy link
Member

@CybotTM CybotTM commented Mar 1, 2026

Summary

Two TYPO3 v13 compatibility fixes for backend modules:

1. Fix XLF label keys for module registration

The 4 module XLF files used non-standard translation unit IDs (title, description, short_description) instead of the TYPO3-expected keys (mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel).

TYPO3's BaseModule resolves labels by appending these standard suffixes to the XLF path — non-standard keys result in empty labels. Empty labels cause DropDownButton validation to fail with InvalidArgumentException (code 1667645426), producing a 503 error in the backend.

Affected files:

  • Resources/Private/Language/Modules/overview.xlf
  • Resources/Private/Language/Modules/secrets.xlf
  • Resources/Private/Language/Modules/audit.xlf
  • Resources/Private/Language/Modules/migration.xlf

2. Use tools parent for v13 compatibility

The module used parent => 'admin', but the admin module group was introduced in TYPO3 v14. On v13, only tools exists. Changed to parent => 'tools' which works on both:

  • v13: tools exists natively
  • v14: tools is an alias for admin

Root cause

XLF: BaseModule::createFromConfiguration() (line ~251) appends :mlang_tabs_tab to the labels path when resolving module titles. The XLF files used title as the translation unit ID, which doesn't match, resulting in an empty string. The DropDownRadio item's isValid() check requires a non-empty label and throws when it's missing.

Parent: composer.json declares ^13.4 || ^14.0 support, but parent => 'admin' only works on v14. Modules with non-existent parent silently fail to register.

Test plan

  • Install nr_vault on TYPO3 v14 — all 4 modules load without 503, labels display correctly
  • Install nr_vault on TYPO3 v13 — modules appear under "Admin Tools" with correct labels
  • Module sidebar entries show proper titles (Vault, Secrets, Audit Log, Migration Wizard)

TYPO3's BaseModule resolves module labels by appending standard key
suffixes (mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel)
to the XLF path. The module XLF files used non-standard keys (title,
description, short_description), causing empty labels that trigger
DropDownButton validation errors (InvalidArgumentException 1667645426).

Rename translation unit IDs in all 4 module XLF files to match the
keys TYPO3 expects.

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
@gemini-code-assist
Copy link

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request addresses critical backend module loading and display issues within TYPO3 by standardizing the translation unit IDs in the module's XLF files. By aligning these keys with TYPO3's expected format, the system can correctly resolve module labels, thereby preventing InvalidArgumentException errors and ensuring a stable and functional backend user interface.

Highlights

  • Standardized XLF Label Keys: Updated trans-unit IDs in backend module XLF files to use TYPO3-expected keys (mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel) instead of non-standard ones (title, description, short_description).
  • Backend Module Functionality Fix: This change resolves issues where non-standard keys led to empty labels, causing DropDownButton validation failures and 503 errors in the TYPO3 backend, ensuring modules load and display correctly.
Changelog
  • Resources/Private/Language/Modules/audit.xlf
    • Updated trans-unit IDs from title, description, short_description to mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel respectively.
  • Resources/Private/Language/Modules/migration.xlf
    • Updated trans-unit IDs from title, description, short_description to mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel respectively.
  • Resources/Private/Language/Modules/overview.xlf
    • Updated trans-unit IDs from title, description, short_description to mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel respectively.
  • Resources/Private/Language/Modules/secrets.xlf
    • Updated trans-unit IDs from title, description, short_description to mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel respectively.
Activity
  • No specific activity has been recorded for this pull request yet.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@github-actions
Copy link
Contributor

github-actions bot commented Mar 1, 2026

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

github-actions[bot]
github-actions bot previously approved these changes Mar 1, 2026
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated approval for solo maintainer project

This PR has passed all automated quality gates:

  • ✅ Static analysis (PHPStan)
  • ✅ Code style (PHP-CS-Fixer)
  • ✅ Unit & functional tests
  • ✅ Security scanning
  • ✅ Dependency review

See SECURITY_CONTROLS.md for compensating controls documentation.

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request addresses a critical bug causing 503 errors in the backend by correcting the translation unit IDs in the backend module XLF files. The changes replace non-standard keys (title, description, short_description) with the TYPO3-standard keys (mlang_tabs_tab, mlang_labels_tabdescr, mlang_labels_tablabel) across all four module language files. This ensures that module labels are resolved correctly by TYPO3's BaseModule, preventing the InvalidArgumentException. The changes are consistent, correct, and directly fix the root cause described.

The 'admin' module group was introduced in TYPO3 v14. On v13, only
'tools' exists as the admin tools parent module. Using 'admin' causes
the vault modules to silently fail to register on v13.

Change to 'tools' which works on both versions:
- v13: 'tools' exists natively
- v14: 'tools' is an alias for 'admin'

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated approval for solo maintainer project

This PR has passed all automated quality gates:

  • ✅ Static analysis (PHPStan)
  • ✅ Code style (PHP-CS-Fixer)
  • ✅ Unit & functional tests
  • ✅ Security scanning
  • ✅ Dependency review

See SECURITY_CONTROLS.md for compensating controls documentation.

@CybotTM CybotTM merged commit 9931127 into main Mar 1, 2026
86 of 87 checks passed
@CybotTM CybotTM deleted the fix/xlf-module-label-keys branch March 1, 2026 08:28
github-merge-queue bot pushed a commit to netresearch/t3x-nr-llm that referenced this pull request Mar 1, 2026
## Summary

- Fix backend module using `parent => 'admin'` which only exists in
TYPO3 v14
- On v13, the `admin` group doesn't exist — modules with a non-existent
parent silently fail to register
- Changed to `parent => 'tools'` which works on both versions:
  - v13: `tools` exists natively as the admin tools group
  - v14: `tools` is an alias for the new `admin` group

## Context

`composer.json` declares `^13.4 || ^14.0` support, but the module
registration only worked on v14.

Same issue was fixed in nr_vault:
netresearch/t3x-nr-vault#92

## Test plan

- [ ] Install nr_llm on TYPO3 v14 — LLM module appears under Admin Tools
- [ ] Install nr_llm on TYPO3 v13 — LLM module appears under Admin Tools
- [ ] All submodules (Providers, Models, Configurations, Tasks, Wizard)
accessible from docheader dropdown
CybotTM added a commit to netresearch/t3x-cowriter that referenced this pull request Mar 1, 2026
… RTE

- Add seed-pages.sql with demo page tree (4 pages, 5 RTE content elements)
- Add seed-pages host command for manual re-seeding
- Auto-import seed data (pages + Ollama config) in install scripts
- Auto-activate cowriter RTE preset via page.tsconfig (TYPO3 standard)
- Update Makefile: use ollama-pull target, handle errors gracefully

Upstream fixes released for dependency issues discovered during testing:
- nr_vault v0.4.1: XLF label keys + module parent v13 compat (netresearch/t3x-nr-vault#92)
- nr_llm v0.2.2: module parent v13 compat (netresearch/t3x-nr-llm#74)

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
CybotTM added a commit to netresearch/t3x-cowriter that referenced this pull request Mar 1, 2026
… RTE

- Add seed-pages.sql with demo page tree (4 pages, 5 RTE content elements)
- Add seed-pages host command for manual re-seeding
- Auto-import seed data (pages + Ollama config) in install scripts
- Auto-activate cowriter RTE preset via page.tsconfig (TYPO3 standard)
- Update Makefile: use ollama-pull target, handle errors gracefully

Upstream fixes released for dependency issues discovered during testing:
- nr_vault v0.4.1: XLF label keys + module parent v13 compat (netresearch/t3x-nr-vault#92)
- nr_llm v0.2.2: module parent v13 compat (netresearch/t3x-nr-llm#74)

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
CybotTM added a commit to netresearch/t3x-cowriter that referenced this pull request Mar 2, 2026
… RTE

- Add seed-pages.sql with demo page tree (4 pages, 5 RTE content elements)
- Add seed-pages host command for manual re-seeding
- Auto-import seed data (pages + Ollama config) in install scripts
- Auto-activate cowriter RTE preset via page.tsconfig (TYPO3 standard)
- Update Makefile: use ollama-pull target, handle errors gracefully

Upstream fixes released for dependency issues discovered during testing:
- nr_vault v0.4.1: XLF label keys + module parent v13 compat (netresearch/t3x-nr-vault#92)
- nr_llm v0.2.2: module parent v13 compat (netresearch/t3x-nr-llm#74)

Signed-off-by: Sebastian Mendel <info@sebastianmendel.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant